<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: zzf
  Date: 2021/1/8
  Time: 14:49
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
    <form action="${pageContext.request.contextPath}/emp/add" method="post">
        员工姓名：<input type="text" name="empName" /><br/>
        社会保险号：<input type="text" name="ssn" /><br/>
        所属部门：
        <select name="department.deptId">
            <c:forEach items="${requestScope.deptList}" var="dept">
                <option value="${dept.deptId}">${dept.deptName}</option>
            </c:forEach>
        </select>
        <br>
        <button type="submit">保存</button>
    </form>
</body>
</html>
